$(document).ready(function(){
	// 图表创建
	var myChart = echarts.init(document.getElementById('chartsDiv'));
    myChart.setOption({
        title: {
            text: "Desplace los limites de la barra para hacer 'zoom' ",
            textStyle:{
            	color:"#336699"
            },
            textAlign:"left"
        },
        tooltip: {
	        trigger: 'axis',
	        formatter:function(params){
	        	// console.log('-- tooltip formatter --')
	        	// console.log(params)
	        	return params[0].axisValue+'<br>温度：'+params[0].value+'  °C';
	        }
	    },
        legend: {
        	right:20,
            data:['Temperatura(T)-(azotea_1)Es0000F001M']
        },
        xAxis: {
            
            type: 'category',
        	boundaryGap: false,
        	data: ["17/07","18/07","19/07","20/07","21/07","22/07","23/07"]
        },
        yAxis: {
	        type: 'value',
	        min: 25,
	        max: 32,
	        axisLabel: {
	            formatter: function(value,index){
	            	// console.log(value)
	            	// console.log(index)
            		return value+' °C';
	            }
	        }
	    },
        series: [{
            name: 'Temperatura(T)-(azotea_1)Es0000F001M',
            type: 'line',
            data: [25,28.5,29,28,29,30,28,29],
            itemStyle:{
            	normal:{
            		color:'#2b6ba9'
            	}
            },
            areaStyle: {normal: {}}
        }]
    });

});